package itheima.edu.info.Exdents.Inface;

import java.lang.reflect.Array;
import java.util.Arrays;

public class ShuZu {
    public static void main(String[] args) {
        int [] arr ={34,323,43,23,56,34,544,3};
       int b= arr.length-1;
        for (int a = 0; a < b; b--) {
            for (int i = 0; i < b; i++) {
                if (arr[i]>arr[i+1]){
                    int t=arr[i+1];
                    arr[i+1]=arr[i];
                    arr[i]=t;
                }
            }
        }
        /*for (int i = 0; i < arr.length; i++) {
            System.out.print(arr[i]+" ");*/
        System.out.println(Arrays.toString(arr));
        }

}

